/*
 
 * @Date: 2019-02-14 17:31:45 
 * @Last Modified by:  
 * @Last Modified time: 2019-02-20 18:33:10
 */

import * as ActionTypes from './ActionTypes';

const initialState = {
    webViewUri: '',
    webViewType: 'default',
    scanningType: 'default',
    qiniuBaseUri: 'http://qiniu.lingyouhui.vip/',
    qiniuToken: '',
    notiVisible: true, // 公告是否显示
    ignoreVisonList: [], // 用户忽略版本列表
    isFirstApp: true, // 是否第一次进入app
};

export default GlobalReducer = (state = initialState, action) => {
    switch (action.type) {
        case ActionTypes.SET_GLOBALINFO:
            return {
                ...state,
                ...action.payload.globalInfo,
            }
        default:
            return state;
    }
}